home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 039a / mawk.zip / FIN.H < prev    next >
C/C++ Source or Header  |  1991-04-07  |  1KB  |  49 lines

  1.  
  2. /********************************************
  3. fin.h
  4. copyright 1991, Michael D. Brennan
  5.  
  6. This is a source file for mawk, an implementation of
  7. the Awk programming language as defined in
  8. Aho, Kernighan and Weinberger, The AWK Programming Language,
  9. Addison-Wesley, 1988.
  10.  
  11. See the accompaning file, LIMITATIONS, for restrictions
  12. regarding modification and redistribution of this
  13. program in source or binary form.
  14. ********************************************/
  15.  
  16. /*$Log:    fin.h,v $
  17.  * Revision 2.1  91/04/08  08:23:11  brennan
  18.  * VERSION 0.97
  19.  * 
  20. */
  21.  
  22. /* fin.h */
  23.  
  24. #ifndef  FIN_H
  25. #define  FIN_H
  26. /* structure to control input files */
  27.  
  28. typedef struct {
  29. int  fd ;
  30. FILE *fp ;   /* NULL unless interactive */
  31. char *buff ;
  32. char *buffp ;
  33. short flags ;
  34. }  FIN ;
  35.  
  36. #define  MAIN_FLAG    1   /* part of main input stream if on */
  37. #define  EOF_FLAG     2
  38.  
  39. FIN *  PROTO (FINdopen, (int, int) );
  40. FIN *  PROTO (FINopen, (char *, int) );
  41. void   PROTO (FINclose, (FIN *) ) ;
  42. char*  PROTO (FINgets, (FIN *, unsigned *) ) ;
  43. unsigned PROTO ( fillbuff, (int, char *, unsigned) ) ;
  44.  
  45.  
  46. extern  FIN  *main_fin ;  /* for the main input stream */
  47. int   PROTO( open_main, (void) ) ;
  48. #endif  /* FIN_H */
  49.